<?php if( ! defined('BASEPATH') ) exit('No direct script access allowed');
	
	class Subscriber_authenticate {
		
		function Subscriber_authenticate(){
			$this -> obj = get_instance();
		}	
		
		function check_login(){
			$login = $this -> obj -> session -> userdata('bid_subscriber_session');
			if( $login != true){
				combine_session('warning', 'Please login, if you want to your histories. Thank you!');
				redirect(base_url());
			}
			return $login;
		}
		
		function logout(){
			$this -> obj -> session -> unset_userdata('bid_subscriber_session', '');
			redirect(base_url());
		}
		
	}
?>